using System.Collections.Generic;

namespace Data.DataAccessObjects.Base
{
    public interface IDao<TEntity, TKeyType>
    {
        IList<TEntity> GetAll();
        int GetCount();
        TEntity GetById(TKeyType id);
        IList<TEntity> GetBy(string propertyName, object value);
        TKeyType Save(TEntity entity);
        void Update(TEntity entity);
        void Delete(TEntity entity);
        void Refresh(TEntity entity);
    }
}